#pragma once
#define SIZE 1024
#define FLUSH_NONE 0
#define FLUSH_LINE 1
#define FLUSH_FULL 2
typedef struct IO_FILE
{
    int flag; // 刷新方式
    int fileno; // 文件描述符
 
    char outbuffer[SIZE];
    int cap;
    int size;
}MyFILE;


MyFILE* mfopen(const char *path, const char *mode);
int mfwrite(const void *ptr, int num, MyFILE *stream);
void mfflush(MyFILE *stream);
void mfclose(MyFILE *stream);
